<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
<!-- qopenglshaderprogram.cpp -->
  <title>QOpenGLShaderProgram Class | Qt GUI 5.14.2</title>
  <link rel="stylesheet" type="text/css" href="style/offline-simple.css" />
  <script type="text/javascript">
    document.getElementsByTagName("link").item(0).setAttribute("href", "style/offline.css");
    // loading style sheet breaks anchors that were jumped to before
    // so force jumping to anchor again
    setTimeout(function() {
        var anchor = location.hash;
        // need to jump to different anchor first (e.g. none)
        location.hash = "#";
        setTimeout(function() {
            location.hash = anchor;
        }, 0);
    }, 0);
  </script>
</head>
<body>
<div class="header" id="qtdocheader">
  <div class="main">
    <div class="main-rounded">
      <div class="navigationbar">
        <table><tr>
<td ><a href="../qtdoc/index.html">Qt 5.14</a></td><td ><a href="qtgui-index.html">Qt GUI</a></td><td ><a href="qtgui-module.html">C++ Classes</a></td><td >QOpenGLShaderProgram</td></tr></table><table class="buildversion"><tr>
<td id="buildversion" width="100%" align="right"><a href="qtgui-index.html">Qt 5.14.2 Reference Documentation</a></td>
        </tr></table>
      </div>
    </div>
<div class="content">
<div class="line">
<div class="content mainContent">
<div class="sidebar">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#static-public-members">Static Public Members</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
<li class="level2"><a href="#introduction">Introduction</a></li>
<li class="level2"><a href="#writing-portable-shaders">Writing Portable Shaders</a></li>
<li class="level2"><a href="#simple-shader-example">Simple Shader Example</a></li>
<li class="level2"><a href="#binary-shaders-and-programs">Binary Shaders and Programs</a></li>
</ul>
</div>
<div class="sidebar-content" id="sidebar-content"></div></div>
<h1 class="title">QOpenGLShaderProgram Class</h1>
<!-- $$$QOpenGLShaderProgram-brief -->
<p>The QOpenGLShaderProgram class allows OpenGL shader programs to be linked and used. <a href="#details">More...</a></p>
<!-- @@@QOpenGLShaderProgram -->
<div class="table"><table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> Header:</td><td class="memItemRight bottomAlign">   <span class="preprocessor">#include &lt;QOpenGLShaderProgram&gt;</span>
</td></tr><tr><td class="memItemLeft rightAlign topAlign"> qmake:</td><td class="memItemRight bottomAlign"> QT += gui</td></tr><tr><td class="memItemLeft rightAlign topAlign"> Since:</td><td class="memItemRight bottomAlign"> Qt 5.0</td></tr><tr><td class="memItemLeft rightAlign topAlign"> Inherits:</td><td class="memItemRight bottomAlign"> <a href="../qtcore/qobject.html">QObject</a></td></tr></table></div><p>This class was introduced in Qt 5.0.</p>
<ul>
<li><a href="qopenglshaderprogram-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-functions"></a>
<h2 id="public-functions">Public Functions</h2>
<div class="table"><table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#QOpenGLShaderProgram">QOpenGLShaderProgram</a></b>(QObject *<i>parent</i> = nullptr)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#dtor.QOpenGLShaderProgram">~QOpenGLShaderProgram</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addCacheableShaderFromSourceCode">addCacheableShaderFromSourceCode</a></b>(QOpenGLShader::ShaderType <i>type</i>, const char *<i>source</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addCacheableShaderFromSourceCode-1">addCacheableShaderFromSourceCode</a></b>(QOpenGLShader::ShaderType <i>type</i>, const QByteArray &amp;<i>source</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addCacheableShaderFromSourceCode-2">addCacheableShaderFromSourceCode</a></b>(QOpenGLShader::ShaderType <i>type</i>, const QString &amp;<i>source</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addCacheableShaderFromSourceFile">addCacheableShaderFromSourceFile</a></b>(QOpenGLShader::ShaderType <i>type</i>, const QString &amp;<i>fileName</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addShader">addShader</a></b>(QOpenGLShader *<i>shader</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a></b>(QOpenGLShader::ShaderType <i>type</i>, const char *<i>source</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addShaderFromSourceCode-1">addShaderFromSourceCode</a></b>(QOpenGLShader::ShaderType <i>type</i>, const QByteArray &amp;<i>source</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addShaderFromSourceCode-2">addShaderFromSourceCode</a></b>(QOpenGLShader::ShaderType <i>type</i>, const QString &amp;<i>source</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a></b>(QOpenGLShader::ShaderType <i>type</i>, const QString &amp;<i>fileName</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a></b>(const char *<i>name</i>) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#attributeLocation-1">attributeLocation</a></b>(const QByteArray &amp;<i>name</i>) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#attributeLocation-2">attributeLocation</a></b>(const QString &amp;<i>name</i>) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#bind">bind</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#bindAttributeLocation">bindAttributeLocation</a></b>(const char *<i>name</i>, int <i>location</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#bindAttributeLocation-1">bindAttributeLocation</a></b>(const QByteArray &amp;<i>name</i>, int <i>location</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#bindAttributeLocation-2">bindAttributeLocation</a></b>(const QString &amp;<i>name</i>, int <i>location</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#create">create</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QVector&lt;float&gt; </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#defaultInnerTessellationLevels">defaultInnerTessellationLevels</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QVector&lt;float&gt; </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#defaultOuterTessellationLevels">defaultOuterTessellationLevels</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a></b>(int <i>location</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#disableAttributeArray-1">disableAttributeArray</a></b>(const char *<i>name</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a></b>(int <i>location</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#enableAttributeArray-1">enableAttributeArray</a></b>(const char *<i>name</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#isLinked">isLinked</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#link">link</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QString </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#log">log</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#maxGeometryOutputVertices">maxGeometryOutputVertices</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#patchVertexCount">patchVertexCount</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> GLuint </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#programId">programId</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#release">release</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#removeAllShaders">removeAllShaders</a></b>()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#removeShader">removeShader</a></b>(QOpenGLShader *<i>shader</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a></b>(int <i>location</i>, const GLfloat *<i>values</i>, int <i>tupleSize</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-1">setAttributeArray</a></b>(int <i>location</i>, const QVector2D *<i>values</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-2">setAttributeArray</a></b>(int <i>location</i>, const QVector3D *<i>values</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-3">setAttributeArray</a></b>(int <i>location</i>, const QVector4D *<i>values</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-4">setAttributeArray</a></b>(int <i>location</i>, GLenum <i>type</i>, const void *<i>values</i>, int <i>tupleSize</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-5">setAttributeArray</a></b>(const char *<i>name</i>, const GLfloat *<i>values</i>, int <i>tupleSize</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-6">setAttributeArray</a></b>(const char *<i>name</i>, const QVector2D *<i>values</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-7">setAttributeArray</a></b>(const char *<i>name</i>, const QVector3D *<i>values</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-8">setAttributeArray</a></b>(const char *<i>name</i>, const QVector4D *<i>values</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeArray-9">setAttributeArray</a></b>(const char *<i>name</i>, GLenum <i>type</i>, const void *<i>values</i>, int <i>tupleSize</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeBuffer">setAttributeBuffer</a></b>(int <i>location</i>, GLenum <i>type</i>, int <i>offset</i>, int <i>tupleSize</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeBuffer-1">setAttributeBuffer</a></b>(const char *<i>name</i>, GLenum <i>type</i>, int <i>offset</i>, int <i>tupleSize</i>, int <i>stride</i> = 0)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a></b>(int <i>location</i>, GLfloat <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-1">setAttributeValue</a></b>(int <i>location</i>, GLfloat <i>x</i>, GLfloat <i>y</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-2">setAttributeValue</a></b>(int <i>location</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-3">setAttributeValue</a></b>(int <i>location</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>, GLfloat <i>w</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-4">setAttributeValue</a></b>(int <i>location</i>, const QVector2D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-5">setAttributeValue</a></b>(int <i>location</i>, const QVector3D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-6">setAttributeValue</a></b>(int <i>location</i>, const QVector4D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-7">setAttributeValue</a></b>(int <i>location</i>, const QColor &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-8">setAttributeValue</a></b>(int <i>location</i>, const GLfloat *<i>values</i>, int <i>columns</i>, int <i>rows</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-9">setAttributeValue</a></b>(const char *<i>name</i>, GLfloat <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-10">setAttributeValue</a></b>(const char *<i>name</i>, GLfloat <i>x</i>, GLfloat <i>y</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-11">setAttributeValue</a></b>(const char *<i>name</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-12">setAttributeValue</a></b>(const char *<i>name</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>, GLfloat <i>w</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-13">setAttributeValue</a></b>(const char *<i>name</i>, const QVector2D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-14">setAttributeValue</a></b>(const char *<i>name</i>, const QVector3D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-15">setAttributeValue</a></b>(const char *<i>name</i>, const QVector4D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-16">setAttributeValue</a></b>(const char *<i>name</i>, const QColor &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setAttributeValue-17">setAttributeValue</a></b>(const char *<i>name</i>, const GLfloat *<i>values</i>, int <i>columns</i>, int <i>rows</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setDefaultInnerTessellationLevels">setDefaultInnerTessellationLevels</a></b>(const QVector&lt;float&gt; &amp;<i>levels</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setDefaultOuterTessellationLevels">setDefaultOuterTessellationLevels</a></b>(const QVector&lt;float&gt; &amp;<i>levels</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setPatchVertexCount">setPatchVertexCount</a></b>(int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a></b>(int <i>location</i>, GLfloat <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-1">setUniformValue</a></b>(int <i>location</i>, GLint <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-36">setUniformValue</a></b>(const char *<i>name</i>, const QColor &amp;<i>color</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-37">setUniformValue</a></b>(const char *<i>name</i>, const QPoint &amp;<i>point</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-38">setUniformValue</a></b>(const char *<i>name</i>, const QPointF &amp;<i>point</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-39">setUniformValue</a></b>(const char *<i>name</i>, const QSize &amp;<i>size</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-40">setUniformValue</a></b>(const char *<i>name</i>, const QSizeF &amp;<i>size</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-41">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix2x2 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-42">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix2x3 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-43">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix2x4 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-44">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix3x2 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-45">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix3x3 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-46">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix3x4 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-47">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix4x2 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-48">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix4x3 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-49">setUniformValue</a></b>(const char *<i>name</i>, const QMatrix4x4 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-50">setUniformValue</a></b>(const char *<i>name</i>, const GLfloat [2][2] <i>value</i> = 2)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-51">setUniformValue</a></b>(const char *<i>name</i>, const GLfloat [3][3] <i>value</i> = 3)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-52">setUniformValue</a></b>(const char *<i>name</i>, const GLfloat [4][4] <i>value</i> = 4)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-53">setUniformValue</a></b>(const char *<i>name</i>, const QTransform &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-2">setUniformValue</a></b>(int <i>location</i>, GLuint <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-3">setUniformValue</a></b>(int <i>location</i>, GLfloat <i>x</i>, GLfloat <i>y</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-4">setUniformValue</a></b>(int <i>location</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-5">setUniformValue</a></b>(int <i>location</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>, GLfloat <i>w</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-6">setUniformValue</a></b>(int <i>location</i>, const QVector2D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-7">setUniformValue</a></b>(int <i>location</i>, const QVector3D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-8">setUniformValue</a></b>(int <i>location</i>, const QVector4D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-9">setUniformValue</a></b>(int <i>location</i>, const QColor &amp;<i>color</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-10">setUniformValue</a></b>(int <i>location</i>, const QPoint &amp;<i>point</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-11">setUniformValue</a></b>(int <i>location</i>, const QPointF &amp;<i>point</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-12">setUniformValue</a></b>(int <i>location</i>, const QSize &amp;<i>size</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-13">setUniformValue</a></b>(int <i>location</i>, const QSizeF &amp;<i>size</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-14">setUniformValue</a></b>(int <i>location</i>, const QMatrix2x2 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-15">setUniformValue</a></b>(int <i>location</i>, const QMatrix2x3 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-16">setUniformValue</a></b>(int <i>location</i>, const QMatrix2x4 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-17">setUniformValue</a></b>(int <i>location</i>, const QMatrix3x2 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-18">setUniformValue</a></b>(int <i>location</i>, const QMatrix3x3 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-19">setUniformValue</a></b>(int <i>location</i>, const QMatrix3x4 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-20">setUniformValue</a></b>(int <i>location</i>, const QMatrix4x2 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-21">setUniformValue</a></b>(int <i>location</i>, const QMatrix4x3 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-22">setUniformValue</a></b>(int <i>location</i>, const QMatrix4x4 &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-23">setUniformValue</a></b>(int <i>location</i>, const GLfloat [2][2] <i>value</i> = 2)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-24">setUniformValue</a></b>(int <i>location</i>, const GLfloat [3][3] <i>value</i> = 3)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-25">setUniformValue</a></b>(int <i>location</i>, const GLfloat [4][4] <i>value</i> = 4)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-26">setUniformValue</a></b>(int <i>location</i>, const QTransform &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-27">setUniformValue</a></b>(const char *<i>name</i>, GLfloat <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-28">setUniformValue</a></b>(const char *<i>name</i>, GLint <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-29">setUniformValue</a></b>(const char *<i>name</i>, GLuint <i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-30">setUniformValue</a></b>(const char *<i>name</i>, GLfloat <i>x</i>, GLfloat <i>y</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-31">setUniformValue</a></b>(const char *<i>name</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-32">setUniformValue</a></b>(const char *<i>name</i>, GLfloat <i>x</i>, GLfloat <i>y</i>, GLfloat <i>z</i>, GLfloat <i>w</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-33">setUniformValue</a></b>(const char *<i>name</i>, const QVector2D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-34">setUniformValue</a></b>(const char *<i>name</i>, const QVector3D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValue-35">setUniformValue</a></b>(const char *<i>name</i>, const QVector4D &amp;<i>value</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray">setUniformValueArray</a></b>(int <i>location</i>, const GLfloat *<i>values</i>, int <i>count</i>, int <i>tupleSize</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-1">setUniformValueArray</a></b>(int <i>location</i>, const GLint *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-2">setUniformValueArray</a></b>(int <i>location</i>, const GLuint *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-3">setUniformValueArray</a></b>(int <i>location</i>, const QVector2D *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-4">setUniformValueArray</a></b>(int <i>location</i>, const QVector3D *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-5">setUniformValueArray</a></b>(int <i>location</i>, const QVector4D *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-6">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix2x2 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-7">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix2x3 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-8">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix2x4 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-9">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix3x2 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-10">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix3x3 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-11">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix3x4 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-12">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix4x2 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-13">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix4x3 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-14">setUniformValueArray</a></b>(int <i>location</i>, const QMatrix4x4 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-15">setUniformValueArray</a></b>(const char *<i>name</i>, const GLfloat *<i>values</i>, int <i>count</i>, int <i>tupleSize</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-16">setUniformValueArray</a></b>(const char *<i>name</i>, const GLint *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-17">setUniformValueArray</a></b>(const char *<i>name</i>, const GLuint *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-18">setUniformValueArray</a></b>(const char *<i>name</i>, const QVector2D *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-19">setUniformValueArray</a></b>(const char *<i>name</i>, const QVector3D *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-20">setUniformValueArray</a></b>(const char *<i>name</i>, const QVector4D *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-21">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix2x2 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-22">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix2x3 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-23">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix2x4 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-24">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix3x2 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-25">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix3x3 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-26">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix3x4 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-27">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix4x2 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-28">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix4x3 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#setUniformValueArray-29">setUniformValueArray</a></b>(const char *<i>name</i>, const QMatrix4x4 *<i>values</i>, int <i>count</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QList&lt;QOpenGLShader *&gt; </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#shaders">shaders</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#uniformLocation">uniformLocation</a></b>(const char *<i>name</i>) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#uniformLocation-1">uniformLocation</a></b>(const QByteArray &amp;<i>name</i>) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#uniformLocation-2">uniformLocation</a></b>(const QString &amp;<i>name</i>) const</td></tr>
</table></div>
<a name="static-public-members"></a>
<h2 id="static-public-members">Static Public Members</h2>
<div class="table"><table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qopenglshaderprogram.html#hasOpenGLShaderPrograms">hasOpenGLShaderPrograms</a></b>(QOpenGLContext *<i>context</i> = nullptr)</td></tr>
</table></div>
<a name="details"></a>
<!-- $$$QOpenGLShaderProgram-description -->
<div class="descr">
<h2 id="details">Detailed Description</h2>
<a name="introduction"></a>
<h3 id="introduction">Introduction</h3>
<p>This class supports shader programs written in the OpenGL Shading Language (GLSL) and in the OpenGL/ES Shading Language (GLSL/ES).</p>
<p><a href="qopenglshader.html">QOpenGLShader</a> and QOpenGLShaderProgram shelter the programmer from the details of compiling and linking vertex and fragment shaders.</p>
<p>The following example creates a vertex shader program using the supplied source <code>code</code>. Once compiled and linked, the shader program is activated in the current <a href="qopenglcontext.html">QOpenGLContext</a> by calling <a href="qopenglshaderprogram.html#bind">QOpenGLShaderProgram::bind</a>():</p>
<pre class="cpp">

  <span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span> shader(<span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span><span class="operator">::</span>Vertex);
  shader<span class="operator">.</span>compileSourceCode(code);

  <span class="type"><a href="qopenglshaderprogram.html#QOpenGLShaderProgram">QOpenGLShaderProgram</a></span> program(context);
  program<span class="operator">.</span>addShader(<span class="operator">&amp;</span>shader);
  program<span class="operator">.</span>link();

  program<span class="operator">.</span>bind();

</pre>
<a name="writing-portable-shaders"></a>
<h3 id="writing-portable-shaders">Writing Portable Shaders</h3>
<p>Shader programs can be difficult to reuse across OpenGL implementations because of varying levels of support for standard vertex attributes and uniform variables. In particular, GLSL/ES lacks all of the standard variables that are present on desktop OpenGL systems: <code>gl_Vertex</code>, <code>gl_Normal</code>, <code>gl_Color</code>, and so on. Desktop OpenGL lacks the variable qualifiers <code>highp</code>, <code>mediump</code>, and <code>lowp</code>.</p>
<p>The QOpenGLShaderProgram class makes the process of writing portable shaders easier by prefixing all shader programs with the following lines on desktop OpenGL:</p>
<pre class="cpp">

  <span class="preprocessor">#define highp</span>
  <span class="preprocessor">#define mediump</span>
  <span class="preprocessor">#define lowp</span>

</pre>
<p>This makes it possible to run most GLSL/ES shader programs on desktop systems. The programmer should restrict themselves to just features that are present in GLSL/ES, and avoid standard variable names that only work on the desktop.</p>
<a name="simple-shader-example"></a>
<h3 id="simple-shader-example">Simple Shader Example</h3>
<pre class="cpp">

  program<span class="operator">.</span>addShaderFromSourceCode(<span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span><span class="operator">::</span>Vertex<span class="operator">,</span>
      <span class="string">&quot;attribute highp vec4 vertex;\n&quot;</span>
      <span class="string">&quot;uniform highp mat4 matrix;\n&quot;</span>
      <span class="string">&quot;void main(void)\n&quot;</span>
      <span class="string">&quot;{\n&quot;</span>
      <span class="string">&quot;   gl_Position = matrix * vertex;\n&quot;</span>
      <span class="string">&quot;}&quot;</span>);
  program<span class="operator">.</span>addShaderFromSourceCode(<span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span><span class="operator">::</span>Fragment<span class="operator">,</span>
      <span class="string">&quot;uniform mediump vec4 color;\n&quot;</span>
      <span class="string">&quot;void main(void)\n&quot;</span>
      <span class="string">&quot;{\n&quot;</span>
      <span class="string">&quot;   gl_FragColor = color;\n&quot;</span>
      <span class="string">&quot;}&quot;</span>);
  program<span class="operator">.</span>link();
  program<span class="operator">.</span>bind();

  <span class="type">int</span> vertexLocation <span class="operator">=</span> program<span class="operator">.</span>attributeLocation(<span class="string">&quot;vertex&quot;</span>);
  <span class="type">int</span> matrixLocation <span class="operator">=</span> program<span class="operator">.</span>uniformLocation(<span class="string">&quot;matrix&quot;</span>);
  <span class="type">int</span> colorLocation <span class="operator">=</span> program<span class="operator">.</span>uniformLocation(<span class="string">&quot;color&quot;</span>);

</pre>
<p>With the above shader program active, we can draw a green triangle as follows:</p>
<pre class="cpp">

  <span class="keyword">static</span> GLfloat <span class="keyword">const</span> triangleVertices<span class="operator">[</span><span class="operator">]</span> <span class="operator">=</span> {
      <span class="number">60.0f</span><span class="operator">,</span>  <span class="number">10.0f</span><span class="operator">,</span>  <span class="number">0.0f</span><span class="operator">,</span>
      <span class="number">110.0f</span><span class="operator">,</span> <span class="number">110.0f</span><span class="operator">,</span> <span class="number">0.0f</span><span class="operator">,</span>
      <span class="number">10.0f</span><span class="operator">,</span>  <span class="number">110.0f</span><span class="operator">,</span> <span class="number">0.0f</span>
  };

  <span class="type"><a href="qcolor.html">QColor</a></span> color(<span class="number">0</span><span class="operator">,</span> <span class="number">255</span><span class="operator">,</span> <span class="number">0</span><span class="operator">,</span> <span class="number">255</span>);

  QMatrix4x4 pmvMatrix;
  pmvMatrix<span class="operator">.</span>ortho(rect());

  program<span class="operator">.</span>enableAttributeArray(vertexLocation);
  program<span class="operator">.</span>setAttributeArray(vertexLocation<span class="operator">,</span> triangleVertices<span class="operator">,</span> <span class="number">3</span>);
  program<span class="operator">.</span>setUniformValue(matrixLocation<span class="operator">,</span> pmvMatrix);
  program<span class="operator">.</span>setUniformValue(colorLocation<span class="operator">,</span> color);

  glDrawArrays(GL_TRIANGLES<span class="operator">,</span> <span class="number">0</span><span class="operator">,</span> <span class="number">3</span>);

  program<span class="operator">.</span>disableAttributeArray(vertexLocation);

</pre>
<a name="binary-shaders-and-programs"></a>
<h3 id="binary-shaders-and-programs">Binary Shaders and Programs</h3>
<p>Binary shaders may be specified using <code>glShaderBinary()</code> on the return value from <a href="qopenglshader.html#shaderId">QOpenGLShader::shaderId</a>(). The <a href="qopenglshader.html">QOpenGLShader</a> instance containing the binary can then be added to the shader program with <a href="qopenglshaderprogram.html#addShader">addShader</a>() and linked in the usual fashion with <a href="qopenglshaderprogram.html#link">link</a>().</p>
<p>Binary programs may be specified using <code>glProgramBinaryOES()</code> on the return value from <a href="qopenglshaderprogram.html#programId">programId</a>(). Then the application should call <a href="qopenglshaderprogram.html#link">link</a>(), which will notice that the program has already been specified and linked, allowing other operations to be performed on the shader program. The shader program's id can be explicitly created using the <a href="qopenglshaderprogram.html#create">create</a>() function.</p>
<a name="caching-program-binaries"></a>
<h4 id="caching-program-binaries">Caching Program Binaries</h4>
<p>As of Qt 5.9, support for caching program binaries on disk is built in. To enable this, switch to using <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceCode">addCacheableShaderFromSourceCode</a>() and <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceFile">addCacheableShaderFromSourceFile</a>(). With an OpenGL ES 3.x context or support for <code>GL_ARB_get_program_binary</code>, this will transparently cache program binaries under <a href="../qtcore/qstandardpaths.html#StandardLocation-enum">QStandardPaths::GenericCacheLocation</a> or <a href="../qtcore/qstandardpaths.html#StandardLocation-enum">QStandardPaths::CacheLocation</a>. When support is not available, calling the cacheable function variants is equivalent to the normal ones.</p>
<p><b>Note: </b>Some drivers do not have any binary formats available, even though they advertise the extension or offer OpenGL ES 3.0&#x2e; In this case program binary support will be disabled.</p></div>
<p><b>See also </b><a href="qopenglshader.html">QOpenGLShader</a>.</p>
<!-- @@@QOpenGLShaderProgram -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$QOpenGLShaderProgram[overload1]$$$QOpenGLShaderProgramQObject* -->
<h3 class="fn" id="QOpenGLShaderProgram"><a name="QOpenGLShaderProgram"></a>QOpenGLShaderProgram::<span class="name">QOpenGLShaderProgram</span>(<span class="type"><a href="../qtcore/qobject.html#QObject">QObject</a></span> *<i>parent</i> = nullptr)</h3>
<p>Constructs a new shader program and attaches it to <i>parent</i>. The program will be invalid until <a href="qopenglshaderprogram.html#addShader">addShader</a>() is called.</p>
<p>The shader program will be associated with the current <a href="qopenglcontext.html">QOpenGLContext</a>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>().</p>
<!-- @@@QOpenGLShaderProgram -->
<!-- $$$~QOpenGLShaderProgram[overload1]$$$~QOpenGLShaderProgram -->
<h3 class="fn" id="dtor.QOpenGLShaderProgram"><a name="dtor.QOpenGLShaderProgram"></a><code>[virtual] </code>QOpenGLShaderProgram::<span class="name">~QOpenGLShaderProgram</span>()</h3>
<p>Deletes this shader program.</p>
<!-- @@@~QOpenGLShaderProgram -->
<!-- $$$addCacheableShaderFromSourceCode[overload1]$$$addCacheableShaderFromSourceCodeQOpenGLShader::ShaderTypeconstchar* -->
<h3 class="fn" id="addCacheableShaderFromSourceCode"><a name="addCacheableShaderFromSourceCode"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addCacheableShaderFromSourceCode</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type">char</span> *<i>source</i>)</h3>
<p>Registers the shader of the specified <i>type</i> and <i>source</i> to this program. Unlike <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>(), this function does not perform compilation. Compilation is deferred to <a href="qopenglshaderprogram.html#link">link</a>(), and may not happen at all, because <a href="qopenglshaderprogram.html#link">link</a>() may potentially use a program binary from Qt's shader disk cache. This will typically lead to a significant increase in performance.</p>
<p>Returns true if the shader has been registered or, in the non-cached case, compiled successfully; false if there was an error. The compilation error messages can be retrieved via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>When the disk cache is disabled, via <a href="../qtcore/qt.html#ApplicationAttribute-enum">Qt::AA_DisableShaderDiskCache</a> for example, or the OpenGL context has no support for context binaries, calling this function is equivalent to <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>().</p>
<p>This function was introduced in Qt 5.9.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>() and <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceFile">addCacheableShaderFromSourceFile</a>().</p>
<!-- @@@addCacheableShaderFromSourceCode -->
<!-- $$$addCacheableShaderFromSourceCode$$$addCacheableShaderFromSourceCodeQOpenGLShader::ShaderTypeconstQByteArray& -->
<h3 class="fn" id="addCacheableShaderFromSourceCode-1"><a name="addCacheableShaderFromSourceCode-1"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addCacheableShaderFromSourceCode</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type"><a href="../qtcore/qbytearray.html">QByteArray</a></span> &amp;<i>source</i>)</h3>
<p>This is an overloaded function.</p>
<p>Registers the shader of the specified <i>type</i> and <i>source</i> to this program. Unlike <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>(), this function does not perform compilation. Compilation is deferred to <a href="qopenglshaderprogram.html#link">link</a>(), and may not happen at all, because <a href="qopenglshaderprogram.html#link">link</a>() may potentially use a program binary from Qt's shader disk cache. This will typically lead to a significant increase in performance.</p>
<p>Returns true if the shader has been registered or, in the non-cached case, compiled successfully; false if there was an error. The compilation error messages can be retrieved via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>When the disk cache is disabled, via <a href="../qtcore/qt.html#ApplicationAttribute-enum">Qt::AA_DisableShaderDiskCache</a> for example, or the OpenGL context has no support for context binaries, calling this function is equivalent to <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>().</p>
<p>This function was introduced in Qt 5.9.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>() and <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceFile">addCacheableShaderFromSourceFile</a>().</p>
<!-- @@@addCacheableShaderFromSourceCode -->
<!-- $$$addCacheableShaderFromSourceCode$$$addCacheableShaderFromSourceCodeQOpenGLShader::ShaderTypeconstQString& -->
<h3 class="fn" id="addCacheableShaderFromSourceCode-2"><a name="addCacheableShaderFromSourceCode-2"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addCacheableShaderFromSourceCode</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>source</i>)</h3>
<p>This is an overloaded function.</p>
<p>Registers the shader of the specified <i>type</i> and <i>source</i> to this program. Unlike <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>(), this function does not perform compilation. Compilation is deferred to <a href="qopenglshaderprogram.html#link">link</a>(), and may not happen at all, because <a href="qopenglshaderprogram.html#link">link</a>() may potentially use a program binary from Qt's shader disk cache. This will typically lead to a significant increase in performance.</p>
<p>When the disk cache is disabled, via <a href="../qtcore/qt.html#ApplicationAttribute-enum">Qt::AA_DisableShaderDiskCache</a> for example, or the OpenGL context has no support for context binaries, calling this function is equivalent to <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>().</p>
<p>This function was introduced in Qt 5.9.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>() and <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceFile">addCacheableShaderFromSourceFile</a>().</p>
<!-- @@@addCacheableShaderFromSourceCode -->
<!-- $$$addCacheableShaderFromSourceFile[overload1]$$$addCacheableShaderFromSourceFileQOpenGLShader::ShaderTypeconstQString& -->
<h3 class="fn" id="addCacheableShaderFromSourceFile"><a name="addCacheableShaderFromSourceFile"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addCacheableShaderFromSourceFile</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>fileName</i>)</h3>
<p>Registers the shader of the specified <i>type</i> and <i>fileName</i> to this program. Unlike <a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>(), this function does not perform compilation. Compilation is deferred to <a href="qopenglshaderprogram.html#link">link</a>(), and may not happen at all, because <a href="qopenglshaderprogram.html#link">link</a>() may potentially use a program binary from Qt's shader disk cache. This will typically lead to a significant increase in performance.</p>
<p>Returns true if the file has been read successfully, false if the file could not be opened or the normal, non-cached compilation of the shader has failed. The compilation error messages can be retrieved via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>When the disk cache is disabled, via <a href="../qtcore/qt.html#ApplicationAttribute-enum">Qt::AA_DisableShaderDiskCache</a> for example, or the OpenGL context has no support for context binaries, calling this function is equivalent to <a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>().</p>
<p>This function was introduced in Qt 5.9.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>() and <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceCode">addCacheableShaderFromSourceCode</a>().</p>
<!-- @@@addCacheableShaderFromSourceFile -->
<!-- $$$addShader[overload1]$$$addShaderQOpenGLShader* -->
<h3 class="fn" id="addShader"><a name="addShader"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addShader</span>(<span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span> *<i>shader</i>)</h3>
<p>Adds a compiled <i>shader</i> to this shader program. Returns <code>true</code> if the shader could be added, or false otherwise.</p>
<p>Ownership of the <i>shader</i> object remains with the caller. It will not be deleted when this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance is deleted. This allows the caller to add the same shader to multiple shader programs.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>(), <a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>(), <a href="qopenglshaderprogram.html#removeShader">removeShader</a>(), <a href="qopenglshaderprogram.html#link">link</a>(), and <a href="qopenglshaderprogram.html#removeAllShaders">removeAllShaders</a>().</p>
<!-- @@@addShader -->
<!-- $$$addShaderFromSourceCode[overload1]$$$addShaderFromSourceCodeQOpenGLShader::ShaderTypeconstchar* -->
<h3 class="fn" id="addShaderFromSourceCode"><a name="addShaderFromSourceCode"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addShaderFromSourceCode</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type">char</span> *<i>source</i>)</h3>
<p>Compiles <i>source</i> as a shader of the specified <i>type</i> and adds it to this shader program. Returns <code>true</code> if compilation was successful, false otherwise. The compilation errors and warnings will be made available via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>This function is intended to be a short-cut for quickly adding vertex and fragment shaders to a shader program without creating an instance of <a href="qopenglshader.html">QOpenGLShader</a> first.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>(), <a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>(), <a href="qopenglshaderprogram.html#removeShader">removeShader</a>(), <a href="qopenglshaderprogram.html#link">link</a>(), <a href="qopenglshaderprogram.html#log">log</a>(), and <a href="qopenglshaderprogram.html#removeAllShaders">removeAllShaders</a>().</p>
<!-- @@@addShaderFromSourceCode -->
<!-- $$$addShaderFromSourceCode$$$addShaderFromSourceCodeQOpenGLShader::ShaderTypeconstQByteArray& -->
<h3 class="fn" id="addShaderFromSourceCode-1"><a name="addShaderFromSourceCode-1"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addShaderFromSourceCode</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type"><a href="../qtcore/qbytearray.html">QByteArray</a></span> &amp;<i>source</i>)</h3>
<p>This is an overloaded function.</p>
<p>Compiles <i>source</i> as a shader of the specified <i>type</i> and adds it to this shader program. Returns <code>true</code> if compilation was successful, false otherwise. The compilation errors and warnings will be made available via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>This function is intended to be a short-cut for quickly adding vertex and fragment shaders to a shader program without creating an instance of <a href="qopenglshader.html">QOpenGLShader</a> first.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>(), <a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>(), <a href="qopenglshaderprogram.html#removeShader">removeShader</a>(), <a href="qopenglshaderprogram.html#link">link</a>(), <a href="qopenglshaderprogram.html#log">log</a>(), and <a href="qopenglshaderprogram.html#removeAllShaders">removeAllShaders</a>().</p>
<!-- @@@addShaderFromSourceCode -->
<!-- $$$addShaderFromSourceCode$$$addShaderFromSourceCodeQOpenGLShader::ShaderTypeconstQString& -->
<h3 class="fn" id="addShaderFromSourceCode-2"><a name="addShaderFromSourceCode-2"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addShaderFromSourceCode</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>source</i>)</h3>
<p>This is an overloaded function.</p>
<p>Compiles <i>source</i> as a shader of the specified <i>type</i> and adds it to this shader program. Returns <code>true</code> if compilation was successful, false otherwise. The compilation errors and warnings will be made available via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>This function is intended to be a short-cut for quickly adding vertex and fragment shaders to a shader program without creating an instance of <a href="qopenglshader.html">QOpenGLShader</a> first.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>(), <a href="qopenglshaderprogram.html#addShaderFromSourceFile">addShaderFromSourceFile</a>(), <a href="qopenglshaderprogram.html#removeShader">removeShader</a>(), <a href="qopenglshaderprogram.html#link">link</a>(), <a href="qopenglshaderprogram.html#log">log</a>(), and <a href="qopenglshaderprogram.html#removeAllShaders">removeAllShaders</a>().</p>
<!-- @@@addShaderFromSourceCode -->
<!-- $$$addShaderFromSourceFile[overload1]$$$addShaderFromSourceFileQOpenGLShader::ShaderTypeconstQString& -->
<h3 class="fn" id="addShaderFromSourceFile"><a name="addShaderFromSourceFile"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">addShaderFromSourceFile</span>(<span class="type"><a href="qopenglshader.html#ShaderTypeBit-enum">QOpenGLShader::ShaderType</a></span> <i>type</i>, const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>fileName</i>)</h3>
<p>Compiles the contents of <i>fileName</i> as a shader of the specified <i>type</i> and adds it to this shader program. Returns <code>true</code> if compilation was successful, false otherwise. The compilation errors and warnings will be made available via <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>This function is intended to be a short-cut for quickly adding vertex and fragment shaders to a shader program without creating an instance of <a href="qopenglshader.html">QOpenGLShader</a> first.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>() and <a href="qopenglshaderprogram.html#addShaderFromSourceCode">addShaderFromSourceCode</a>().</p>
<!-- @@@addShaderFromSourceFile -->
<!-- $$$attributeLocation[overload1]$$$attributeLocationconstchar* -->
<h3 class="fn" id="attributeLocation"><a name="attributeLocation"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">attributeLocation</span>(const <span class="type">char</span> *<i>name</i>) const</h3>
<p>Returns the location of the attribute <i>name</i> within this shader program's parameter list. Returns -1 if <i>name</i> is not a valid attribute for this shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#uniformLocation">uniformLocation</a>() and <a href="qopenglshaderprogram.html#bindAttributeLocation">bindAttributeLocation</a>().</p>
<!-- @@@attributeLocation -->
<!-- $$$attributeLocation$$$attributeLocationconstQByteArray& -->
<h3 class="fn" id="attributeLocation-1"><a name="attributeLocation-1"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">attributeLocation</span>(const <span class="type"><a href="../qtcore/qbytearray.html">QByteArray</a></span> &amp;<i>name</i>) const</h3>
<p>This is an overloaded function.</p>
<p>Returns the location of the attribute <i>name</i> within this shader program's parameter list. Returns -1 if <i>name</i> is not a valid attribute for this shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#uniformLocation">uniformLocation</a>() and <a href="qopenglshaderprogram.html#bindAttributeLocation">bindAttributeLocation</a>().</p>
<!-- @@@attributeLocation -->
<!-- $$$attributeLocation$$$attributeLocationconstQString& -->
<h3 class="fn" id="attributeLocation-2"><a name="attributeLocation-2"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">attributeLocation</span>(const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>name</i>) const</h3>
<p>This is an overloaded function.</p>
<p>Returns the location of the attribute <i>name</i> within this shader program's parameter list. Returns -1 if <i>name</i> is not a valid attribute for this shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#uniformLocation">uniformLocation</a>() and <a href="qopenglshaderprogram.html#bindAttributeLocation">bindAttributeLocation</a>().</p>
<!-- @@@attributeLocation -->
<!-- $$$bind[overload1]$$$bind -->
<h3 class="fn" id="bind"><a name="bind"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">bind</span>()</h3>
<p>Binds this shader program to the active <a href="qopenglcontext.html">QOpenGLContext</a> and makes it the current shader program. Any previously bound shader program is released. This is equivalent to calling <code>glUseProgram()</code> on <a href="qopenglshaderprogram.html#programId">programId</a>(). Returns <code>true</code> if the program was successfully bound; false otherwise. If the shader program has not yet been linked, or it needs to be re-linked, this function will call <a href="qopenglshaderprogram.html#link">link</a>().</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#link">link</a>() and <a href="qopenglshaderprogram.html#release">release</a>().</p>
<!-- @@@bind -->
<!-- $$$bindAttributeLocation[overload1]$$$bindAttributeLocationconstchar*int -->
<h3 class="fn" id="bindAttributeLocation"><a name="bindAttributeLocation"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">bindAttributeLocation</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">int</span> <i>location</i>)</h3>
<p>Binds the attribute <i>name</i> to the specified <i>location</i>. This function can be called before or after the program has been linked. Any attributes that have not been explicitly bound when the program is linked will be assigned locations automatically.</p>
<p>When this function is called after the program has been linked, the program will need to be relinked for the change to take effect.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a>().</p>
<!-- @@@bindAttributeLocation -->
<!-- $$$bindAttributeLocation$$$bindAttributeLocationconstQByteArray&int -->
<h3 class="fn" id="bindAttributeLocation-1"><a name="bindAttributeLocation-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">bindAttributeLocation</span>(const <span class="type"><a href="../qtcore/qbytearray.html">QByteArray</a></span> &amp;<i>name</i>, <span class="type">int</span> <i>location</i>)</h3>
<p>This is an overloaded function.</p>
<p>Binds the attribute <i>name</i> to the specified <i>location</i>. This function can be called before or after the program has been linked. Any attributes that have not been explicitly bound when the program is linked will be assigned locations automatically.</p>
<p>When this function is called after the program has been linked, the program will need to be relinked for the change to take effect.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a>().</p>
<!-- @@@bindAttributeLocation -->
<!-- $$$bindAttributeLocation$$$bindAttributeLocationconstQString&int -->
<h3 class="fn" id="bindAttributeLocation-2"><a name="bindAttributeLocation-2"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">bindAttributeLocation</span>(const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>name</i>, <span class="type">int</span> <i>location</i>)</h3>
<p>This is an overloaded function.</p>
<p>Binds the attribute <i>name</i> to the specified <i>location</i>. This function can be called before or after the program has been linked. Any attributes that have not been explicitly bound when the program is linked will be assigned locations automatically.</p>
<p>When this function is called after the program has been linked, the program will need to be relinked for the change to take effect.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a>().</p>
<!-- @@@bindAttributeLocation -->
<!-- $$$create[overload1]$$$create -->
<h3 class="fn" id="create"><a name="create"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">create</span>()</h3>
<p>Requests the shader program's id to be created immediately. Returns <code>true</code> if successful; <code>false</code> otherwise.</p>
<p>This function is primarily useful when combining <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> with other OpenGL functions that operate directly on the shader program id, like <code>GL_OES_get_program_binary</code>.</p>
<p>When the shader program is used normally, the shader program's id will be created on demand.</p>
<p>This function was introduced in Qt 5.3.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#programId">programId</a>().</p>
<!-- @@@create -->
<!-- $$$defaultInnerTessellationLevels[overload1]$$$defaultInnerTessellationLevels -->
<h3 class="fn" id="defaultInnerTessellationLevels"><a name="defaultInnerTessellationLevels"></a><span class="type"><a href="../qtcore/qvector.html">QVector</a></span>&lt;<span class="type">float</span>&gt; QOpenGLShaderProgram::<span class="name">defaultInnerTessellationLevels</span>() const</h3>
<p>Returns the default inner tessellation levels to be used by the tessellation primitive generator in the event that the tessellation control shader does not output them. For more details on OpenGL and Tessellation shaders see <a href="http://www.opengl.org/wiki/Tessellation_Shader">OpenGL Tessellation Shaders</a>.</p>
<p>Returns a <a href="../qtcore/qvector.html">QVector</a> of floats describing the inner tessellation levels. The vector will always have two elements but not all of them make sense for every mode of tessellation.</p>
<p><b>Note: </b>This returns the global OpenGL state value. It is not specific to this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance.</p><p><b>Note: </b>This function is only supported with OpenGL &gt;= 4.0 and will not return valid results with OpenGL ES 3.2&#x2e;</p><p><b>See also </b><a href="qopenglshaderprogram.html#setDefaultInnerTessellationLevels">setDefaultInnerTessellationLevels</a>() and <a href="qopenglshaderprogram.html#defaultOuterTessellationLevels">defaultOuterTessellationLevels</a>().</p>
<!-- @@@defaultInnerTessellationLevels -->
<!-- $$$defaultOuterTessellationLevels[overload1]$$$defaultOuterTessellationLevels -->
<h3 class="fn" id="defaultOuterTessellationLevels"><a name="defaultOuterTessellationLevels"></a><span class="type"><a href="../qtcore/qvector.html">QVector</a></span>&lt;<span class="type">float</span>&gt; QOpenGLShaderProgram::<span class="name">defaultOuterTessellationLevels</span>() const</h3>
<p>Returns the default outer tessellation levels to be used by the tessellation primitive generator in the event that the tessellation control shader does not output them. For more details on OpenGL and Tessellation shaders see <a href="http://www.opengl.org/wiki/Tessellation_Shader">OpenGL Tessellation Shaders</a>.</p>
<p>Returns a <a href="../qtcore/qvector.html">QVector</a> of floats describing the outer tessellation levels. The vector will always have four elements but not all of them make sense for every mode of tessellation.</p>
<p><b>Note: </b>This returns the global OpenGL state value. It is not specific to this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance.</p><p><b>Note: </b>This function is only supported with OpenGL &gt;= 4.0 and will not return valid results with OpenGL ES 3.2&#x2e;</p><p><b>See also </b><a href="qopenglshaderprogram.html#setDefaultOuterTessellationLevels">setDefaultOuterTessellationLevels</a>() and <a href="qopenglshaderprogram.html#defaultInnerTessellationLevels">defaultInnerTessellationLevels</a>().</p>
<!-- @@@defaultOuterTessellationLevels -->
<!-- $$$disableAttributeArray[overload1]$$$disableAttributeArrayint -->
<h3 class="fn" id="disableAttributeArray"><a name="disableAttributeArray"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">disableAttributeArray</span>(<span class="type">int</span> <i>location</i>)</h3>
<p>Disables the vertex array at <i>location</i> in this shader program that was enabled by a previous call to <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>().</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), and <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@disableAttributeArray -->
<!-- $$$disableAttributeArray$$$disableAttributeArrayconstchar* -->
<h3 class="fn" id="disableAttributeArray-1"><a name="disableAttributeArray-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">disableAttributeArray</span>(const <span class="type">char</span> *<i>name</i>)</h3>
<p>This is an overloaded function.</p>
<p>Disables the vertex array called <i>name</i> in this shader program that was enabled by a previous call to <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>().</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), and <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@disableAttributeArray -->
<!-- $$$enableAttributeArray[overload1]$$$enableAttributeArrayint -->
<h3 class="fn" id="enableAttributeArray"><a name="enableAttributeArray"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">enableAttributeArray</span>(<span class="type">int</span> <i>location</i>)</h3>
<p>Enables the vertex array at <i>location</i> in this shader program so that the value set by <a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>() on <i>location</i> will be used by the shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), and <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@enableAttributeArray -->
<!-- $$$enableAttributeArray$$$enableAttributeArrayconstchar* -->
<h3 class="fn" id="enableAttributeArray-1"><a name="enableAttributeArray-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">enableAttributeArray</span>(const <span class="type">char</span> *<i>name</i>)</h3>
<p>This is an overloaded function.</p>
<p>Enables the vertex array called <i>name</i> in this shader program so that the value set by <a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>() on <i>name</i> will be used by the shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>(), <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), and <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@enableAttributeArray -->
<!-- $$$hasOpenGLShaderPrograms[overload1]$$$hasOpenGLShaderProgramsQOpenGLContext* -->
<h3 class="fn" id="hasOpenGLShaderPrograms"><a name="hasOpenGLShaderPrograms"></a><code>[static] </code><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">hasOpenGLShaderPrograms</span>(<span class="type"><a href="qopenglcontext.html">QOpenGLContext</a></span> *<i>context</i> = nullptr)</h3>
<p>Returns <code>true</code> if shader programs written in the OpenGL Shading Language (GLSL) are supported on this system; false otherwise.</p>
<p>The <i>context</i> is used to resolve the GLSL extensions. If <i>context</i> is <code>nullptr</code>, then <a href="qopenglcontext.html#currentContext">QOpenGLContext::currentContext</a>() is used.</p>
<!-- @@@hasOpenGLShaderPrograms -->
<!-- $$$isLinked[overload1]$$$isLinked -->
<h3 class="fn" id="isLinked"><a name="isLinked"></a><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">isLinked</span>() const</h3>
<p>Returns <code>true</code> if this shader program has been linked; false otherwise.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#link">link</a>().</p>
<!-- @@@isLinked -->
<!-- $$$link[overload1]$$$link -->
<h3 class="fn" id="link"><a name="link"></a><code>[virtual] </code><span class="type">bool</span> QOpenGLShaderProgram::<span class="name">link</span>()</h3>
<p>Links together the shaders that were added to this program with <a href="qopenglshaderprogram.html#addShader">addShader</a>(). Returns <code>true</code> if the link was successful or false otherwise. If the link failed, the error messages can be retrieved with <a href="qopenglshaderprogram.html#log">log</a>().</p>
<p>Subclasses can override this function to initialize attributes and uniform variables for use in specific shader programs.</p>
<p>If the shader program was already linked, calling this function again will force it to be re-linked.</p>
<p>When shaders were added to this program via <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceCode">addCacheableShaderFromSourceCode</a>() or <a href="qopenglshaderprogram.html#addCacheableShaderFromSourceFile">addCacheableShaderFromSourceFile</a>(), program binaries are supported, and a cached binary is available on disk, actual compilation and linking are skipped. Instead, link() will initialize the program with the binary blob via glProgramBinary(). If there is no cached version of the program or it was generated with a different driver version, the shaders will be compiled from source and the program will get linked normally. This allows seamless upgrading of the graphics drivers, without having to worry about potentially incompatible binary formats.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>() and <a href="qopenglshaderprogram.html#log">log</a>().</p>
<!-- @@@link -->
<!-- $$$log[overload1]$$$log -->
<h3 class="fn" id="log"><a name="log"></a><span class="type"><a href="../qtcore/qstring.html">QString</a></span> QOpenGLShaderProgram::<span class="name">log</span>() const</h3>
<p>Returns the errors and warnings that occurred during the last <a href="qopenglshaderprogram.html#link">link</a>() or <a href="qopenglshaderprogram.html#addShader">addShader</a>() with explicitly specified source code.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#link">link</a>().</p>
<!-- @@@log -->
<!-- $$$maxGeometryOutputVertices[overload1]$$$maxGeometryOutputVertices -->
<h3 class="fn" id="maxGeometryOutputVertices"><a name="maxGeometryOutputVertices"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">maxGeometryOutputVertices</span>() const</h3>
<p>Returns the hardware limit for how many vertices a geometry shader can output.</p>
<!-- @@@maxGeometryOutputVertices -->
<!-- $$$patchVertexCount[overload1]$$$patchVertexCount -->
<h3 class="fn" id="patchVertexCount"><a name="patchVertexCount"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">patchVertexCount</span>() const</h3>
<p>Returns the number of vertices per-patch to be used when rendering.</p>
<p><b>Note: </b>This returns the global OpenGL state value. It is not specific to this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setPatchVertexCount">setPatchVertexCount</a>().</p>
<!-- @@@patchVertexCount -->
<!-- $$$programId[overload1]$$$programId -->
<h3 class="fn" id="programId"><a name="programId"></a><span class="type">GLuint</span> QOpenGLShaderProgram::<span class="name">programId</span>() const</h3>
<p>Returns the OpenGL identifier associated with this shader program.</p>
<p><b>See also </b><a href="qopenglshader.html#shaderId">QOpenGLShader::shaderId</a>().</p>
<!-- @@@programId -->
<!-- $$$release[overload1]$$$release -->
<h3 class="fn" id="release"><a name="release"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">release</span>()</h3>
<p>Releases the active shader program from the current <a href="qopenglcontext.html">QOpenGLContext</a>. This is equivalent to calling <code>glUseProgram(0)</code>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#bind">bind</a>().</p>
<!-- @@@release -->
<!-- $$$removeAllShaders[overload1]$$$removeAllShaders -->
<h3 class="fn" id="removeAllShaders"><a name="removeAllShaders"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">removeAllShaders</span>()</h3>
<p>Removes all of the shaders that were added to this program previously. The <a href="qopenglshader.html">QOpenGLShader</a> objects for the shaders will not be deleted if they were constructed externally. <a href="qopenglshader.html">QOpenGLShader</a> objects that are constructed internally by <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> will be deleted.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>() and <a href="qopenglshaderprogram.html#removeShader">removeShader</a>().</p>
<!-- @@@removeAllShaders -->
<!-- $$$removeShader[overload1]$$$removeShaderQOpenGLShader* -->
<h3 class="fn" id="removeShader"><a name="removeShader"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">removeShader</span>(<span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span> *<i>shader</i>)</h3>
<p>Removes <i>shader</i> from this shader program. The object is not deleted.</p>
<p>The shader program must be valid in the current <a href="qopenglcontext.html">QOpenGLContext</a>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>(), <a href="qopenglshaderprogram.html#link">link</a>(), and <a href="qopenglshaderprogram.html#removeAllShaders">removeAllShaders</a>().</p>
<!-- @@@removeShader -->
<!-- $$$setAttributeArray[overload1]$$$setAttributeArrayintconstGLfloat*intint -->
<h3 class="fn" id="setAttributeArray"><a name="setAttributeArray"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLfloat</span> *<i>values</i>, <span class="type">int</span> <i>tupleSize</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>Sets an array of vertex <i>values</i> on the attribute at <i>location</i> in this shader program. The <i>tupleSize</i> indicates the number of components per vertex (1, 2, 3, or 4), and the <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>location</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>location</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayintconstQVector2D*int -->
<h3 class="fn" id="setAttributeArray-1"><a name="setAttributeArray-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> *<i>values</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>Sets an array of 2D vertex <i>values</i> on the attribute at <i>location</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>location</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>location</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayintconstQVector3D*int -->
<h3 class="fn" id="setAttributeArray-2"><a name="setAttributeArray-2"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> *<i>values</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>Sets an array of 3D vertex <i>values</i> on the attribute at <i>location</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>location</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>location</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayintconstQVector4D*int -->
<h3 class="fn" id="setAttributeArray-3"><a name="setAttributeArray-3"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> *<i>values</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>Sets an array of 4D vertex <i>values</i> on the attribute at <i>location</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>location</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>location</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayintGLenumconstvoid*intint -->
<h3 class="fn" id="setAttributeArray-4"><a name="setAttributeArray-4"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLenum</span> <i>type</i>, const <span class="type">void</span> *<i>values</i>, <span class="type">int</span> <i>tupleSize</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>Sets an array of vertex <i>values</i> on the attribute at <i>location</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The <i>type</i> indicates the type of elements in the <i>values</i> array, usually <code>GL_FLOAT</code>, <code>GL_UNSIGNED_BYTE</code>, etc. The <i>tupleSize</i> indicates the number of components per vertex: 1, 2, 3, or 4.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>location</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>location</i> will be used.</p>
<p>The <a href="qopenglshaderprogram.html#setAttributeBuffer">setAttributeBuffer</a>() function can be used to set the attribute array to an offset within a vertex buffer.</p>
<p><b>Note: </b>Normalization will be enabled. If this is not desired, call glVertexAttribPointer directly through <a href="qopenglfunctions.html">QOpenGLFunctions</a>.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#setAttributeBuffer">setAttributeBuffer</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayconstchar*constGLfloat*intint -->
<h3 class="fn" id="setAttributeArray-5"><a name="setAttributeArray-5"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLfloat</span> *<i>values</i>, <span class="type">int</span> <i>tupleSize</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>This is an overloaded function.</p>
<p>Sets an array of vertex <i>values</i> on the attribute called <i>name</i> in this shader program. The <i>tupleSize</i> indicates the number of components per vertex (1, 2, 3, or 4), and the <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on <i>name</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>name</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayconstchar*constQVector2D*int -->
<h3 class="fn" id="setAttributeArray-6"><a name="setAttributeArray-6"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> *<i>values</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>This is an overloaded function.</p>
<p>Sets an array of 2D vertex <i>values</i> on the attribute called <i>name</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on <i>name</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>name</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayconstchar*constQVector3D*int -->
<h3 class="fn" id="setAttributeArray-7"><a name="setAttributeArray-7"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> *<i>values</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>This is an overloaded function.</p>
<p>Sets an array of 3D vertex <i>values</i> on the attribute called <i>name</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on <i>name</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>name</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayconstchar*constQVector4D*int -->
<h3 class="fn" id="setAttributeArray-8"><a name="setAttributeArray-8"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> *<i>values</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>This is an overloaded function.</p>
<p>Sets an array of 4D vertex <i>values</i> on the attribute called <i>name</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on <i>name</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>name</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeArray$$$setAttributeArrayconstchar*GLenumconstvoid*intint -->
<h3 class="fn" id="setAttributeArray-9"><a name="setAttributeArray-9"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeArray</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLenum</span> <i>type</i>, const <span class="type">void</span> *<i>values</i>, <span class="type">int</span> <i>tupleSize</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>This is an overloaded function.</p>
<p>Sets an array of vertex <i>values</i> on the attribute called <i>name</i> in this shader program. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in <i>values</i>.</p>
<p>The <i>type</i> indicates the type of elements in the <i>values</i> array, usually <code>GL_FLOAT</code>, <code>GL_UNSIGNED_BYTE</code>, etc. The <i>tupleSize</i> indicates the number of components per vertex: 1, 2, 3, or 4.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>name</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>name</i> will be used.</p>
<p>The <a href="qopenglshaderprogram.html#setAttributeBuffer">setAttributeBuffer</a>() function can be used to set the attribute array to an offset within a vertex buffer.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>(), <a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>(), <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>(), <a href="qopenglshaderprogram.html#disableAttributeArray">disableAttributeArray</a>(), and <a href="qopenglshaderprogram.html#setAttributeBuffer">setAttributeBuffer</a>().</p>
<!-- @@@setAttributeArray -->
<!-- $$$setAttributeBuffer[overload1]$$$setAttributeBufferintGLenumintintint -->
<h3 class="fn" id="setAttributeBuffer"><a name="setAttributeBuffer"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeBuffer</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLenum</span> <i>type</i>, <span class="type">int</span> <i>offset</i>, <span class="type">int</span> <i>tupleSize</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>Sets an array of vertex values on the attribute at <i>location</i> in this shader program, starting at a specific <i>offset</i> in the currently bound vertex buffer. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in the value array.</p>
<p>The <i>type</i> indicates the type of elements in the vertex value array, usually <code>GL_FLOAT</code>, <code>GL_UNSIGNED_BYTE</code>, etc. The <i>tupleSize</i> indicates the number of components per vertex: 1, 2, 3, or 4.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>location</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>location</i> will be used.</p>
<p><b>Note: </b>Normalization will be enabled. If this is not desired, call glVertexAttribPointer directly through <a href="qopenglfunctions.html">QOpenGLFunctions</a>.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>().</p>
<!-- @@@setAttributeBuffer -->
<!-- $$$setAttributeBuffer$$$setAttributeBufferconstchar*GLenumintintint -->
<h3 class="fn" id="setAttributeBuffer-1"><a name="setAttributeBuffer-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeBuffer</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLenum</span> <i>type</i>, <span class="type">int</span> <i>offset</i>, <span class="type">int</span> <i>tupleSize</i>, <span class="type">int</span> <i>stride</i> = 0)</h3>
<p>This is an overloaded function.</p>
<p>Sets an array of vertex values on the attribute called <i>name</i> in this shader program, starting at a specific <i>offset</i> in the currently bound vertex buffer. The <i>stride</i> indicates the number of bytes between vertices. A default <i>stride</i> value of zero indicates that the vertices are densely packed in the value array.</p>
<p>The <i>type</i> indicates the type of elements in the vertex value array, usually <code>GL_FLOAT</code>, <code>GL_UNSIGNED_BYTE</code>, etc. The <i>tupleSize</i> indicates the number of components per vertex: 1, 2, 3, or 4.</p>
<p>The array will become active when <a href="qopenglshaderprogram.html#enableAttributeArray">enableAttributeArray</a>() is called on the <i>name</i>. Otherwise the value specified with <a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>() for <i>name</i> will be used.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeArray">setAttributeArray</a>().</p>
<!-- @@@setAttributeBuffer -->
<!-- $$$setAttributeValue[overload1]$$$setAttributeValueintGLfloat -->
<h3 class="fn" id="setAttributeValue"><a name="setAttributeValue"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>value</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintGLfloatGLfloat -->
<h3 class="fn" id="setAttributeValue-1"><a name="setAttributeValue-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to the 2D vector (<i>x</i>, <i>y</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintGLfloatGLfloatGLfloat -->
<h3 class="fn" id="setAttributeValue-2"><a name="setAttributeValue-2"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to the 3D vector (<i>x</i>, <i>y</i>, <i>z</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintGLfloatGLfloatGLfloatGLfloat -->
<h3 class="fn" id="setAttributeValue-3"><a name="setAttributeValue-3"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>, <span class="type">GLfloat</span> <i>w</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to the 4D vector (<i>x</i>, <i>y</i>, <i>z</i>, <i>w</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintconstQVector2D& -->
<h3 class="fn" id="setAttributeValue-4"><a name="setAttributeValue-4"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> &amp;<i>value</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintconstQVector3D& -->
<h3 class="fn" id="setAttributeValue-5"><a name="setAttributeValue-5"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> &amp;<i>value</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintconstQVector4D& -->
<h3 class="fn" id="setAttributeValue-6"><a name="setAttributeValue-6"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> &amp;<i>value</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintconstQColor& -->
<h3 class="fn" id="setAttributeValue-7"><a name="setAttributeValue-7"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qcolor.html">QColor</a></span> &amp;<i>value</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueintconstGLfloat*intint -->
<h3 class="fn" id="setAttributeValue-8"><a name="setAttributeValue-8"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLfloat</span> *<i>values</i>, <span class="type">int</span> <i>columns</i>, <span class="type">int</span> <i>rows</i>)</h3>
<p>Sets the attribute at <i>location</i> in the current context to the contents of <i>values</i>, which contains <i>columns</i> elements, each consisting of <i>rows</i> elements. The <i>rows</i> value should be 1, 2, 3, or 4. This function is typically used to set matrix values and column vectors.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*GLfloat -->
<h3 class="fn" id="setAttributeValue-9"><a name="setAttributeValue-9"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*GLfloatGLfloat -->
<h3 class="fn" id="setAttributeValue-10"><a name="setAttributeValue-10"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to the 2D vector (<i>x</i>, <i>y</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*GLfloatGLfloatGLfloat -->
<h3 class="fn" id="setAttributeValue-11"><a name="setAttributeValue-11"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to the 3D vector (<i>x</i>, <i>y</i>, <i>z</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*GLfloatGLfloatGLfloatGLfloat -->
<h3 class="fn" id="setAttributeValue-12"><a name="setAttributeValue-12"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>, <span class="type">GLfloat</span> <i>w</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to the 4D vector (<i>x</i>, <i>y</i>, <i>z</i>, <i>w</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*constQVector2D& -->
<h3 class="fn" id="setAttributeValue-13"><a name="setAttributeValue-13"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*constQVector3D& -->
<h3 class="fn" id="setAttributeValue-14"><a name="setAttributeValue-14"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*constQVector4D& -->
<h3 class="fn" id="setAttributeValue-15"><a name="setAttributeValue-15"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*constQColor& -->
<h3 class="fn" id="setAttributeValue-16"><a name="setAttributeValue-16"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qcolor.html">QColor</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setAttributeValue$$$setAttributeValueconstchar*constGLfloat*intint -->
<h3 class="fn" id="setAttributeValue-17"><a name="setAttributeValue-17"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setAttributeValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLfloat</span> *<i>values</i>, <span class="type">int</span> <i>columns</i>, <span class="type">int</span> <i>rows</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the attribute called <i>name</i> in the current context to the contents of <i>values</i>, which contains <i>columns</i> elements, each consisting of <i>rows</i> elements. The <i>rows</i> value should be 1, 2, 3, or 4. This function is typically used to set matrix values and column vectors.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setUniformValue">setUniformValue</a>().</p>
<!-- @@@setAttributeValue -->
<!-- $$$setDefaultInnerTessellationLevels[overload1]$$$setDefaultInnerTessellationLevelsconstQVector<float>& -->
<h3 class="fn" id="setDefaultInnerTessellationLevels"><a name="setDefaultInnerTessellationLevels"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setDefaultInnerTessellationLevels</span>(const <span class="type"><a href="../qtcore/qvector.html">QVector</a></span>&lt;<span class="type">float</span>&gt; &amp;<i>levels</i>)</h3>
<p>Sets the default outer tessellation levels to be used by the tessellation primitive generator in the event that the tessellation control shader does not output them to <i>levels</i>. For more details on OpenGL and Tessellation shaders see <a href="http://www.opengl.org/wiki/Tessellation_Shader">OpenGL Tessellation Shaders</a>.</p>
<p>The <i>levels</i> argument should be a <a href="../qtcore/qvector.html">QVector</a> consisting of 2 floats. Not all of the values make sense for all tessellation modes. If you specify a vector with fewer than 2 elements, the remaining elements will be given a default value of 1.</p>
<p><b>Note: </b>This modifies global OpenGL state and is not specific to this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance. You should call this in your render function when needed, as <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> will not apply this for you. This is purely a convenience function.</p><p><b>Note: </b>This function is only available with OpenGL &gt;= 4.0 and is not supported with OpenGL ES 3.2&#x2e;</p><p><b>See also </b><a href="qopenglshaderprogram.html#defaultInnerTessellationLevels">defaultInnerTessellationLevels</a>() and <a href="qopenglshaderprogram.html#setDefaultOuterTessellationLevels">setDefaultOuterTessellationLevels</a>().</p>
<!-- @@@setDefaultInnerTessellationLevels -->
<!-- $$$setDefaultOuterTessellationLevels[overload1]$$$setDefaultOuterTessellationLevelsconstQVector<float>& -->
<h3 class="fn" id="setDefaultOuterTessellationLevels"><a name="setDefaultOuterTessellationLevels"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setDefaultOuterTessellationLevels</span>(const <span class="type"><a href="../qtcore/qvector.html">QVector</a></span>&lt;<span class="type">float</span>&gt; &amp;<i>levels</i>)</h3>
<p>Sets the default outer tessellation levels to be used by the tessellation primitive generator in the event that the tessellation control shader does not output them to <i>levels</i>. For more details on OpenGL and Tessellation shaders see <a href="http://www.opengl.org/wiki/Tessellation_Shader">OpenGL Tessellation Shaders</a>.</p>
<p>The <i>levels</i> argument should be a <a href="../qtcore/qvector.html">QVector</a> consisting of 4 floats. Not all of the values make sense for all tessellation modes. If you specify a vector with fewer than 4 elements, the remaining elements will be given a default value of 1.</p>
<p><b>Note: </b>This modifies global OpenGL state and is not specific to this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance. You should call this in your render function when needed, as <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> will not apply this for you. This is purely a convenience function.</p><p><b>Note: </b>This function is only available with OpenGL &gt;= 4.0 and is not supported with OpenGL ES 3.2&#x2e;</p><p><b>See also </b><a href="qopenglshaderprogram.html#defaultOuterTessellationLevels">defaultOuterTessellationLevels</a>() and <a href="qopenglshaderprogram.html#setDefaultInnerTessellationLevels">setDefaultInnerTessellationLevels</a>().</p>
<!-- @@@setDefaultOuterTessellationLevels -->
<!-- $$$setPatchVertexCount[overload1]$$$setPatchVertexCountint -->
<h3 class="fn" id="setPatchVertexCount"><a name="setPatchVertexCount"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setPatchVertexCount</span>(<span class="type">int</span> <i>count</i>)</h3>
<p>Use this function to specify to OpenGL the number of vertices in a patch to <i>count</i>. A patch is a custom OpenGL primitive whose interpretation is entirely defined by the tessellation shader stages. Therefore, calling this function only makes sense when using a <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> containing tessellation stage shaders. When using OpenGL tessellation, the only primitive that can be rendered with <code>glDraw*()</code> functions is <code>GL_PATCHES</code>.</p>
<p>This is equivalent to calling glPatchParameteri(GL_PATCH_VERTICES, count).</p>
<p><b>Note: </b>This modifies global OpenGL state and is not specific to this <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> instance. You should call this in your render function when needed, as <a href="qopenglshaderprogram.html">QOpenGLShaderProgram</a> will not apply this for you. This is purely a convenience function.</p><p><b>See also </b><a href="qopenglshaderprogram.html#patchVertexCount">patchVertexCount</a>().</p>
<!-- @@@setPatchVertexCount -->
<!-- $$$setUniformValue[overload1]$$$setUniformValueintGLfloat -->
<h3 class="fn" id="setUniformValue"><a name="setUniformValue"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintGLint -->
<h3 class="fn" id="setUniformValue-1"><a name="setUniformValue-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLint</span> <i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQColor& -->
<h3 class="fn" id="setUniformValue-36"><a name="setUniformValue-36"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qcolor.html">QColor</a></span> &amp;<i>color</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to the red, green, blue, and alpha components of <i>color</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQPoint& -->
<h3 class="fn" id="setUniformValue-37"><a name="setUniformValue-37"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="../qtcore/qpoint.html">QPoint</a></span> &amp;<i>point</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable associated with <i>name</i> in the current context to the x and y coordinates of <i>point</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQPointF& -->
<h3 class="fn" id="setUniformValue-38"><a name="setUniformValue-38"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="../qtcore/qpointf.html">QPointF</a></span> &amp;<i>point</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable associated with <i>name</i> in the current context to the x and y coordinates of <i>point</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQSize& -->
<h3 class="fn" id="setUniformValue-39"><a name="setUniformValue-39"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="../qtcore/qsize.html">QSize</a></span> &amp;<i>size</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable associated with <i>name</i> in the current context to the width and height of the given <i>size</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQSizeF& -->
<h3 class="fn" id="setUniformValue-40"><a name="setUniformValue-40"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="../qtcore/qsizef.html">QSizeF</a></span> &amp;<i>size</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable associated with <i>name</i> in the current context to the width and height of the given <i>size</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix2x2& -->
<h3 class="fn" id="setUniformValue-41"><a name="setUniformValue-41"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x2-typedef">QMatrix2x2</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 2x2 matrix <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix2x3& -->
<h3 class="fn" id="setUniformValue-42"><a name="setUniformValue-42"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x3-typedef">QMatrix2x3</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 2x3 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat2x3, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec3.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix2x4& -->
<h3 class="fn" id="setUniformValue-43"><a name="setUniformValue-43"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x4-typedef">QMatrix2x4</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 2x4 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat2x4, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec4.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix3x2& -->
<h3 class="fn" id="setUniformValue-44"><a name="setUniformValue-44"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x2-typedef">QMatrix3x2</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 3x2 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat3x2, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec2.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix3x3& -->
<h3 class="fn" id="setUniformValue-45"><a name="setUniformValue-45"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x3-typedef">QMatrix3x3</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 3x3 matrix <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix3x4& -->
<h3 class="fn" id="setUniformValue-46"><a name="setUniformValue-46"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x4-typedef">QMatrix3x4</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 3x4 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat3x4, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec4.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix4x2& -->
<h3 class="fn" id="setUniformValue-47"><a name="setUniformValue-47"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x2-typedef">QMatrix4x2</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 4x2 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat4x2, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec2.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix4x3& -->
<h3 class="fn" id="setUniformValue-48"><a name="setUniformValue-48"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x3-typedef">QMatrix4x3</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 4x3 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat4x3, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec3.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQMatrix4x4& -->
<h3 class="fn" id="setUniformValue-49"><a name="setUniformValue-49"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qmatrix4x4.html">QMatrix4x4</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 4x4 matrix <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constGLfloat[2][2] -->
<h3 class="fn" id="setUniformValue-50"><a name="setUniformValue-50"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLfloat</span> [<span class="type">2</span>][<span class="type">2</span>] <i>value</i> = 2)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 2x2 matrix <i>value</i>. The matrix elements must be specified in column-major order.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constGLfloat[3][3] -->
<h3 class="fn" id="setUniformValue-51"><a name="setUniformValue-51"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLfloat</span> [<span class="type">3</span>][<span class="type">3</span>] <i>value</i> = 3)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 3x3 matrix <i>value</i>. The matrix elements must be specified in column-major order.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constGLfloat[4][4] -->
<h3 class="fn" id="setUniformValue-52"><a name="setUniformValue-52"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLfloat</span> [<span class="type">4</span>][<span class="type">4</span>] <i>value</i> = 4)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 4x4 matrix <i>value</i>. The matrix elements must be specified in column-major order.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQTransform& -->
<h3 class="fn" id="setUniformValue-53"><a name="setUniformValue-53"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qtransform.html">QTransform</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to a 3x3 transformation matrix <i>value</i> that is specified as a <a href="qtransform.html">QTransform</a> value.</p>
<p>To set a <a href="qtransform.html">QTransform</a> value as a 4x4 matrix in a shader, use <code>setUniformValue(name, QMatrix4x4(value))</code>.</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintGLuint -->
<h3 class="fn" id="setUniformValue-2"><a name="setUniformValue-2"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLuint</span> <i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to <i>value</i>. This function should be used when setting sampler values.</p>
<p><b>Note: </b>This function is not aware of unsigned int support in modern OpenGL versions and therefore treats <i>value</i> as a GLint and calls glUniform1i.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintGLfloatGLfloat -->
<h3 class="fn" id="setUniformValue-3"><a name="setUniformValue-3"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the 2D vector (<i>x</i>, <i>y</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintGLfloatGLfloatGLfloat -->
<h3 class="fn" id="setUniformValue-4"><a name="setUniformValue-4"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the 3D vector (<i>x</i>, <i>y</i>, <i>z</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintGLfloatGLfloatGLfloatGLfloat -->
<h3 class="fn" id="setUniformValue-5"><a name="setUniformValue-5"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>, <span class="type">GLfloat</span> <i>w</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the 4D vector (<i>x</i>, <i>y</i>, <i>z</i>, <i>w</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQVector2D& -->
<h3 class="fn" id="setUniformValue-6"><a name="setUniformValue-6"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQVector3D& -->
<h3 class="fn" id="setUniformValue-7"><a name="setUniformValue-7"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQVector4D& -->
<h3 class="fn" id="setUniformValue-8"><a name="setUniformValue-8"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQColor& -->
<h3 class="fn" id="setUniformValue-9"><a name="setUniformValue-9"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qcolor.html">QColor</a></span> &amp;<i>color</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the red, green, blue, and alpha components of <i>color</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQPoint& -->
<h3 class="fn" id="setUniformValue-10"><a name="setUniformValue-10"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="../qtcore/qpoint.html">QPoint</a></span> &amp;<i>point</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the x and y coordinates of <i>point</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQPointF& -->
<h3 class="fn" id="setUniformValue-11"><a name="setUniformValue-11"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="../qtcore/qpointf.html">QPointF</a></span> &amp;<i>point</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the x and y coordinates of <i>point</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQSize& -->
<h3 class="fn" id="setUniformValue-12"><a name="setUniformValue-12"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="../qtcore/qsize.html">QSize</a></span> &amp;<i>size</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the width and height of the given <i>size</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQSizeF& -->
<h3 class="fn" id="setUniformValue-13"><a name="setUniformValue-13"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="../qtcore/qsizef.html">QSizeF</a></span> &amp;<i>size</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to the width and height of the given <i>size</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix2x2& -->
<h3 class="fn" id="setUniformValue-14"><a name="setUniformValue-14"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x2-typedef">QMatrix2x2</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 2x2 matrix <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix2x3& -->
<h3 class="fn" id="setUniformValue-15"><a name="setUniformValue-15"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x3-typedef">QMatrix2x3</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 2x3 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat2x3, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec3.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix2x4& -->
<h3 class="fn" id="setUniformValue-16"><a name="setUniformValue-16"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x4-typedef">QMatrix2x4</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 2x4 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat2x4, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec4.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix3x2& -->
<h3 class="fn" id="setUniformValue-17"><a name="setUniformValue-17"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x2-typedef">QMatrix3x2</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 3x2 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat3x2, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec2.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix3x3& -->
<h3 class="fn" id="setUniformValue-18"><a name="setUniformValue-18"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x3-typedef">QMatrix3x3</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 3x3 matrix <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix3x4& -->
<h3 class="fn" id="setUniformValue-19"><a name="setUniformValue-19"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x4-typedef">QMatrix3x4</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 3x4 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat3x4, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec4.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix4x2& -->
<h3 class="fn" id="setUniformValue-20"><a name="setUniformValue-20"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x2-typedef">QMatrix4x2</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 4x2 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat4x2, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec2.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix4x3& -->
<h3 class="fn" id="setUniformValue-21"><a name="setUniformValue-21"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x3-typedef">QMatrix4x3</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 4x3 matrix <i>value</i>.</p>
<p><b>Note: </b>This function is not aware of non square matrix support, that is, GLSL types like mat4x3, that is present in modern OpenGL versions. Instead, it treats the uniform as an array of vec3.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQMatrix4x4& -->
<h3 class="fn" id="setUniformValue-22"><a name="setUniformValue-22"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qmatrix4x4.html">QMatrix4x4</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 4x4 matrix <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstGLfloat[2][2] -->
<h3 class="fn" id="setUniformValue-23"><a name="setUniformValue-23"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLfloat</span> [<span class="type">2</span>][<span class="type">2</span>] <i>value</i> = 2)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable at <i>location</i> in the current context to a 2x2 matrix <i>value</i>. The matrix elements must be specified in column-major order.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstGLfloat[3][3] -->
<h3 class="fn" id="setUniformValue-24"><a name="setUniformValue-24"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLfloat</span> [<span class="type">3</span>][<span class="type">3</span>] <i>value</i> = 3)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable at <i>location</i> in the current context to a 3x3 matrix <i>value</i>. The matrix elements must be specified in column-major order.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstGLfloat[4][4] -->
<h3 class="fn" id="setUniformValue-25"><a name="setUniformValue-25"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLfloat</span> [<span class="type">4</span>][<span class="type">4</span>] <i>value</i> = 4)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable at <i>location</i> in the current context to a 4x4 matrix <i>value</i>. The matrix elements must be specified in column-major order.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueintconstQTransform& -->
<h3 class="fn" id="setUniformValue-26"><a name="setUniformValue-26"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qtransform.html">QTransform</a></span> &amp;<i>value</i>)</h3>
<p>Sets the uniform variable at <i>location</i> in the current context to a 3x3 transformation matrix <i>value</i> that is specified as a <a href="qtransform.html">QTransform</a> value.</p>
<p>To set a <a href="qtransform.html">QTransform</a> value as a 4x4 matrix in a shader, use <code>setUniformValue(location, QMatrix4x4(value))</code>.</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*GLfloat -->
<h3 class="fn" id="setUniformValue-27"><a name="setUniformValue-27"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*GLint -->
<h3 class="fn" id="setUniformValue-28"><a name="setUniformValue-28"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLint</span> <i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*GLuint -->
<h3 class="fn" id="setUniformValue-29"><a name="setUniformValue-29"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLuint</span> <i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to <i>value</i>. This function should be used when setting sampler values.</p>
<p><b>Note: </b>This function is not aware of unsigned int support in modern OpenGL versions and therefore treats <i>value</i> as a GLint and calls glUniform1i.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*GLfloatGLfloat -->
<h3 class="fn" id="setUniformValue-30"><a name="setUniformValue-30"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to the 2D vector (<i>x</i>, <i>y</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*GLfloatGLfloatGLfloat -->
<h3 class="fn" id="setUniformValue-31"><a name="setUniformValue-31"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to the 3D vector (<i>x</i>, <i>y</i>, <i>z</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*GLfloatGLfloatGLfloatGLfloat -->
<h3 class="fn" id="setUniformValue-32"><a name="setUniformValue-32"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, <span class="type">GLfloat</span> <i>x</i>, <span class="type">GLfloat</span> <i>y</i>, <span class="type">GLfloat</span> <i>z</i>, <span class="type">GLfloat</span> <i>w</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to the 4D vector (<i>x</i>, <i>y</i>, <i>z</i>, <i>w</i>).</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQVector2D& -->
<h3 class="fn" id="setUniformValue-33"><a name="setUniformValue-33"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQVector3D& -->
<h3 class="fn" id="setUniformValue-34"><a name="setUniformValue-34"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValue$$$setUniformValueconstchar*constQVector4D& -->
<h3 class="fn" id="setUniformValue-35"><a name="setUniformValue-35"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValue</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> &amp;<i>value</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable called <i>name</i> in the current context to <i>value</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValue -->
<!-- $$$setUniformValueArray[overload1]$$$setUniformValueArrayintconstGLfloat*intint -->
<h3 class="fn" id="setUniformValueArray"><a name="setUniformValueArray"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLfloat</span> *<i>values</i>, <span class="type">int</span> <i>count</i>, <span class="type">int</span> <i>tupleSize</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> elements of <i>values</i>. Each element has <i>tupleSize</i> components. The <i>tupleSize</i> must be 1, 2, 3, or 4.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstGLint*int -->
<h3 class="fn" id="setUniformValueArray-1"><a name="setUniformValueArray-1"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLint</span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstGLuint*int -->
<h3 class="fn" id="setUniformValueArray-2"><a name="setUniformValueArray-2"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type">GLuint</span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> elements of <i>values</i>. This overload should be used when setting an array of sampler values.</p>
<p><b>Note: </b>This function is not aware of unsigned int support in modern OpenGL versions and therefore treats <i>values</i> as a GLint and calls glUniform1iv.</p><p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQVector2D*int -->
<h3 class="fn" id="setUniformValueArray-3"><a name="setUniformValueArray-3"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 2D vector elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQVector3D*int -->
<h3 class="fn" id="setUniformValueArray-4"><a name="setUniformValueArray-4"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 3D vector elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQVector4D*int -->
<h3 class="fn" id="setUniformValueArray-5"><a name="setUniformValueArray-5"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 4D vector elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix2x2*int -->
<h3 class="fn" id="setUniformValueArray-6"><a name="setUniformValueArray-6"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x2-typedef">QMatrix2x2</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 2x2 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix2x3*int -->
<h3 class="fn" id="setUniformValueArray-7"><a name="setUniformValueArray-7"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x3-typedef">QMatrix2x3</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 2x3 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix2x4*int -->
<h3 class="fn" id="setUniformValueArray-8"><a name="setUniformValueArray-8"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x4-typedef">QMatrix2x4</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 2x4 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix3x2*int -->
<h3 class="fn" id="setUniformValueArray-9"><a name="setUniformValueArray-9"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x2-typedef">QMatrix3x2</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 3x2 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix3x3*int -->
<h3 class="fn" id="setUniformValueArray-10"><a name="setUniformValueArray-10"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x3-typedef">QMatrix3x3</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 3x3 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix3x4*int -->
<h3 class="fn" id="setUniformValueArray-11"><a name="setUniformValueArray-11"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x4-typedef">QMatrix3x4</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 3x4 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix4x2*int -->
<h3 class="fn" id="setUniformValueArray-12"><a name="setUniformValueArray-12"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x2-typedef">QMatrix4x2</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 4x2 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix4x3*int -->
<h3 class="fn" id="setUniformValueArray-13"><a name="setUniformValueArray-13"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x3-typedef">QMatrix4x3</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 4x3 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayintconstQMatrix4x4*int -->
<h3 class="fn" id="setUniformValueArray-14"><a name="setUniformValueArray-14"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(<span class="type">int</span> <i>location</i>, const <span class="type"><a href="qmatrix4x4.html">QMatrix4x4</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>Sets the uniform variable array at <i>location</i> in the current context to the <i>count</i> 4x4 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constGLfloat*intint -->
<h3 class="fn" id="setUniformValueArray-15"><a name="setUniformValueArray-15"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLfloat</span> *<i>values</i>, <span class="type">int</span> <i>count</i>, <span class="type">int</span> <i>tupleSize</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> elements of <i>values</i>. Each element has <i>tupleSize</i> components. The <i>tupleSize</i> must be 1, 2, 3, or 4.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constGLint*int -->
<h3 class="fn" id="setUniformValueArray-16"><a name="setUniformValueArray-16"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLint</span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constGLuint*int -->
<h3 class="fn" id="setUniformValueArray-17"><a name="setUniformValueArray-17"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type">GLuint</span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> elements of <i>values</i>. This overload should be used when setting an array of sampler values.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQVector2D*int -->
<h3 class="fn" id="setUniformValueArray-18"><a name="setUniformValueArray-18"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector2d.html">QVector2D</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 2D vector elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQVector3D*int -->
<h3 class="fn" id="setUniformValueArray-19"><a name="setUniformValueArray-19"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector3d.html">QVector3D</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 3D vector elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQVector4D*int -->
<h3 class="fn" id="setUniformValueArray-20"><a name="setUniformValueArray-20"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qvector4d.html">QVector4D</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 4D vector elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix2x2*int -->
<h3 class="fn" id="setUniformValueArray-21"><a name="setUniformValueArray-21"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x2-typedef">QMatrix2x2</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 2x2 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix2x3*int -->
<h3 class="fn" id="setUniformValueArray-22"><a name="setUniformValueArray-22"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x3-typedef">QMatrix2x3</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 2x3 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix2x4*int -->
<h3 class="fn" id="setUniformValueArray-23"><a name="setUniformValueArray-23"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix2x4-typedef">QMatrix2x4</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 2x4 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix3x2*int -->
<h3 class="fn" id="setUniformValueArray-24"><a name="setUniformValueArray-24"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x2-typedef">QMatrix3x2</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 3x2 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix3x3*int -->
<h3 class="fn" id="setUniformValueArray-25"><a name="setUniformValueArray-25"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x3-typedef">QMatrix3x3</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 3x3 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix3x4*int -->
<h3 class="fn" id="setUniformValueArray-26"><a name="setUniformValueArray-26"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix3x4-typedef">QMatrix3x4</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 3x4 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix4x2*int -->
<h3 class="fn" id="setUniformValueArray-27"><a name="setUniformValueArray-27"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x2-typedef">QMatrix4x2</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 4x2 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix4x3*int -->
<h3 class="fn" id="setUniformValueArray-28"><a name="setUniformValueArray-28"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qgenericmatrix.html#QMatrix4x3-typedef">QMatrix4x3</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 4x3 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$setUniformValueArray$$$setUniformValueArrayconstchar*constQMatrix4x4*int -->
<h3 class="fn" id="setUniformValueArray-29"><a name="setUniformValueArray-29"></a><span class="type">void</span> QOpenGLShaderProgram::<span class="name">setUniformValueArray</span>(const <span class="type">char</span> *<i>name</i>, const <span class="type"><a href="qmatrix4x4.html">QMatrix4x4</a></span> *<i>values</i>, <span class="type">int</span> <i>count</i>)</h3>
<p>This is an overloaded function.</p>
<p>Sets the uniform variable array called <i>name</i> in the current context to the <i>count</i> 4x4 matrix elements of <i>values</i>.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#setAttributeValue">setAttributeValue</a>().</p>
<!-- @@@setUniformValueArray -->
<!-- $$$shaders[overload1]$$$shaders -->
<h3 class="fn" id="shaders"><a name="shaders"></a><span class="type">QList</span>&lt;<span class="type"><a href="qopenglshader.html">QOpenGLShader</a></span> *&gt; QOpenGLShaderProgram::<span class="name">shaders</span>() const</h3>
<p>Returns a list of all shaders that have been added to this shader program using <a href="qopenglshaderprogram.html#addShader">addShader</a>().</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#addShader">addShader</a>() and <a href="qopenglshaderprogram.html#removeShader">removeShader</a>().</p>
<!-- @@@shaders -->
<!-- $$$uniformLocation[overload1]$$$uniformLocationconstchar* -->
<h3 class="fn" id="uniformLocation"><a name="uniformLocation"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">uniformLocation</span>(const <span class="type">char</span> *<i>name</i>) const</h3>
<p>Returns the location of the uniform variable <i>name</i> within this shader program's parameter list. Returns -1 if <i>name</i> is not a valid uniform variable for this shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a>().</p>
<!-- @@@uniformLocation -->
<!-- $$$uniformLocation$$$uniformLocationconstQByteArray& -->
<h3 class="fn" id="uniformLocation-1"><a name="uniformLocation-1"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">uniformLocation</span>(const <span class="type"><a href="../qtcore/qbytearray.html">QByteArray</a></span> &amp;<i>name</i>) const</h3>
<p>This is an overloaded function.</p>
<p>Returns the location of the uniform variable <i>name</i> within this shader program's parameter list. Returns -1 if <i>name</i> is not a valid uniform variable for this shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a>().</p>
<!-- @@@uniformLocation -->
<!-- $$$uniformLocation$$$uniformLocationconstQString& -->
<h3 class="fn" id="uniformLocation-2"><a name="uniformLocation-2"></a><span class="type">int</span> QOpenGLShaderProgram::<span class="name">uniformLocation</span>(const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &amp;<i>name</i>) const</h3>
<p>This is an overloaded function.</p>
<p>Returns the location of the uniform variable <i>name</i> within this shader program's parameter list. Returns -1 if <i>name</i> is not a valid uniform variable for this shader program.</p>
<p><b>See also </b><a href="qopenglshaderprogram.html#attributeLocation">attributeLocation</a>().</p>
<!-- @@@uniformLocation -->
</div>
        </div>
       </div>
   </div>
   </div>
</div>
<div class="footer">
   <p>
   <acronym title="Copyright">&copy;</acronym> 2020 The Qt Company Ltd.
   Documentation contributions included herein are the copyrights of
   their respective owners.<br/>    The documentation provided herein is licensed under the terms of the    <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation    License version 1.3</a> as published by the Free Software Foundation.<br/>    Qt and respective logos are trademarks of The Qt Company Ltd.     in Finland and/or other countries worldwide. All other trademarks are property
   of their respective owners. </p>
</div>
</body>
</html>
